<!--
 * @Author: Badcandy 568197314@qq.com
 * @Date: 2022-12-18 18:54:16
 * @LastEditors: 晋龍
 * @LastEditTime: 2023-01-16 19:56:44
 * @FilePath: \dcollege\src\views\IndexPage.vue
 * @Description:启动页
 * Copyright (c) 2022 by Badcandy 568197314@qq.com, All Rights Reserved.
-->
<template>
  <div class="indexPage">
    <div>
      <meta v-if="!user" http-equiv="refresh" content="3;URL=/login" />
      <meta v-else http-equiv="refresh" content="3;URL=/home" />
      <div class="page_img">
        <var-image src="../views/login/image/indexPage.png" class="page" alt="indexPage" />
      </div>
      <div class="logo_img">
        <var-image src="../views/login/image/logo.png" class="logo" alt="logo" />
      </div>
    </div>
  </div>
</template>

<script setup>
import { useRouter } from "vue-router";
import { ref } from "vue";

const router = useRouter();
const user = JSON.parse(localStorage.getItem("user"));
</script>

<style lang="less" scoped>
.indexPage {
  background: #fff;
  width: 100%;
  height: 100%;
  .page_img {
    position: relative;
    padding-top: 40%;
    width: 100%;
    padding-bottom: 40%;
    .page {
      width: 100%;
    }
  }
  .logo_img {
    width: 200rem;
    position: relative;
    padding-bottom: 3rem;
    width: 50%;

    .logo {
      margin-left: 50%;
      width: 100%;
    }
  }
}
</style>
